import RoleService from '../service/role-service';
import * as Koa from 'koa';

class roleController {
  private service: RoleService = new RoleService();

  getRoles = async (ctx: Koa.Context) => {
    await this.service.getRoles(ctx);
  };
  delRole = async (ctx: Koa.Context) => {
    await this.service.delRole(ctx);
  };
  addRole = async (ctx: Koa.Context) => {
    await this.service.addRole(ctx);
  };
  updateRole = async (ctx: Koa.Context) => {
    await this.service.updateRole(ctx);
  };
}

export default new roleController();
